package com.yanqu.road.entity.activity.signindraw.cross;

import com.yanqu.road.entity.DataObject;
import com.yanqu.road.entity.FieldTypeAnnotation;

import java.util.Map;
import java.util.Objects;

@FieldTypeAnnotation(tableName = "t_c_sign_in_draw_user_data", desc = "玩家抽奖情况")
public class CrossSignInDrawUserData  extends DataObject {

    @FieldTypeAnnotation(select = true, update = true, desc = "活动ID")
    private int activityId;

    @FieldTypeAnnotation(update = true, desc = "openId")
    private String uid;

    @FieldTypeAnnotation(desc = "奖励")
    private Map<Integer, Integer> rewardMap;

    public int getActivityId() {
        return activityId;
    }

    public void setActivityId(int activityId) {
        if(this.activityId != activityId) {
            this.activityId = activityId;
            setUpdateOption();
        }
    }

    public String getUid() {
        return uid;
    }

    public void setUid(String uid) {
        if(!Objects.equals(this.uid, uid)) {
            this.uid = uid;
            setUpdateOption();
        }
    }

    public Map<Integer, Integer> getRewardMap() {
        return rewardMap;
    }

    public void setRewardMap(Map<Integer, Integer> rewardMap) {
        this.rewardMap = rewardMap;
        setUpdateOption();
    }
}
